
export default {
	namespaced:true,
	state:{
		// 搜索框信息
		search:{},
		// 导航栏信息
		navBar:{},
		// 店铺公告
		notice:{},
		video:{},
		banner:{},
		// 图片橱窗
		window:{},
		// 产品列表
		goods:{},
		image:{}
	},
	mutations:{
		setComponentInfo(state,info){
			info.forEach(item => {
				if (item.type === "search"){
					state.search = item
				} else if (item.type === "navBar"){
					state.navBar = item
				} else if (item.type === "notice"){
					state.notice = item
				} else if (item.type === "video"){
					state.video = item
				} else if (item.type === "banner"){
					state.banner = item
				} else if (item.type === "window"){
					state.window = item
				} else if (item.type === "goods"){
					state.goods = item
				} else if (item.type === 'image'){
					state.image = item
				}
			})
		}
	},
	getters:{},
	actions:{}
}